<template>
    <div class="index">
        <el-card class="box-card font-left">
            <div slot="header" class="clearfix">
                <span>已完成审核文章</span>
            </div>
                <el-table
                    :data="tableData"
                    style="width: 100%">
                    <el-table-column
                    label="序列"
                    width="180">
                    <template slot-scope="scope">
                        <span style="margin-left: 10px">{{ scope.row.ARID }}</span>
                    </template>
                    </el-table-column>                    
                    <el-table-column
                    label="完成时间"
                    width="180">
                    <template slot-scope="scope">
                        <i class="el-icon-time"></i>
                        <span style="margin-left: 10px">{{ scope.row.CTime }}</span>
                    </template>
                    </el-table-column>
                    <el-table-column
                    label="攥写人"
                    width="180">
                    <template slot-scope="scope">
                        <span style="margin-left: 10px">{{ scope.row.User.Count }}</span>
                    </template>                       
                    </el-table-column>
                    <el-table-column
                    label="文章名称"
                    width="180">
                    <template slot-scope="scope">
                        <span style="margin-left: 10px">{{ scope.row.Tile }}</span>
                    </template>                       
                    </el-table-column>
                    <el-table-column
                    label="关键字"
                    width="180">
                    <template slot-scope="scope">
                        <span style="margin-left: 10px">{{ scope.row.KeyWords }}</span>
                    </template>                       
                    </el-table-column>
                    <el-table-column
                    label="来源"
                    width="180">
                    <template slot-scope="scope">
                        <span style="margin-left: 10px">{{ scope.row.Source }}</span>
                    </template>                       
                    </el-table-column>
                    <el-table-column
                    label="审核人"
                    width="180">
                    <template slot-scope="scope">
                        <span style="margin-left: 10px">{{ scope.row.Examiner.Count }}</span>
                    </template>                       
                    </el-table-column>
                    <el-table-column label="操作">
                    <template slot-scope="scope">
                        <el-button
                        size="mini"
                        @click="viewContent(scope.row.ArticalContent.Conntent)">内容查看</el-button>
                        <el-dialog
                        title="文章内容"
                        :visible.sync="dialogVisible"
                        width="80%"
                        >
                            <span>{{Content}}</span>
                            <span slot="footer" class="dialog-footer">
                                <el-button type="primary" @click="dialogVisible = false">确 定</el-button>
                            </span>
                        </el-dialog>
                    </template>
                    </el-table-column>
                </el-table>
        </el-card>
    </div>
</template>

<script>
    export default {
        data() {
            return {
                tableData:[               
                ],
                dialogVisible:false,
                Content:'',
            }
        },
        methods: {
            viewContent(row) {
                this.dialogVisible=true
                this.Content = row
                
            },
            handleDelete(index, row) {
                console.log(index, row);
            },        
        },
        mounted(){
            this.$axios.post("/Artical/search",{"W":{"ExamineStatus":{"not":0}}}).then(res=>{
                let result = res.data.d.L;
                this.tableData = result
            })
        }
    }
</script>

<style scoped>
    .box-card{
        margin: 5% 40px
    }
    .font-left{
        text-align:left;
        font-weight:bold
    }
</style>